package com.czr.vo;

import com.alibaba.fastjson.JSONArray;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotEmpty;
import java.io.Serializable;
import java.util.List;

/**
 * <p>
 * 帖子表
 * </p>
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="czr_reply对象", description="帖子")
public class CzrReplyVo extends Model<CzrReplyVo> {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键(不用传)")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "评论")
    @TableField("comment")
    private String comment;

    @ApiModelProperty(value = "发帖时间")
    @TableField("pub_time")
    private String pubTime;

    @ApiModelProperty(value = "点赞数")
    @TableField("like_count")
    private Integer likeCount;

    @ApiModelProperty(value = "用于二级评论关联一级评论")
    @TableField("replyId")
    private Integer replyId;

    @ApiModelProperty(value = "级别")
    @TableField("level")
    private Integer level;
    @ApiModelProperty(value = "回帖昵称")
    @TableField("nick_name")
    private String nickName;

    @ApiModelProperty(value = "回帖头像")
    @TableField("user_logo")
    private String userLogo;

    @ApiModelProperty(value = "评论用户")
    @TableField("old_userId")
    private Integer oldUserId;

    @ApiModelProperty(value = "评论用户昵称")
    private String oldNickName;

    @ApiModelProperty(value = "评论用户头像")
    private String oldUserLogo;

    @ApiModelProperty(value = "是否点赞")
    private Integer isLike;

    @ApiModelProperty(value = "关联回复id")
    @TableField("old_replyId")
    private Integer oldReplyId;

    @ApiModelProperty(value = "下级评论")
    @TableField("userId")
    private List<CzrReplyVo> CzrReplyVoList;

    @ApiModelProperty(value = "下级数量")
    @TableField("replyCount")
    private Integer replyCount;

    @ApiModelProperty(value = "是否可以删除(0:不可以 1：可以)")
    @TableField("isDel")
    private Integer isDel;

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
